import type { MockMethod } from 'vite-plugin-mock'
export default [
  // 权限节点列表 
  {
    url: '/api/menu/list',
    method: 'get',
    response: () => {
      return {
        code: 0,
        msg: 'ok',
        data: [
          {
            id: 1,
            name: '首页',
            ename: 'main',
            menu: 0,
            route: '/wther',
            icon: 'Menu',
            // 这个属性是用来分别点击的是哪个菜单项
            index: '1'
          },
          {
            id: 2,
            name: '数字农场',
            ename: 'digtalFarm',
            menu: 1,
            route: '',
            icon: 'Operation',
            index: '2',
            children: [
              {
                id: 20,
                name: '人员管理',
                ename: 'personManage',
                menu: 0,
                route: '/people',
                icon: 'User',
                index: '3'
              }
            ]
          },
          {
            id: 3,
            name: "采收计划",
            ename: "purchaseOrder",
            menu: 0,
            route: "/harvest",
            icon: "List",
            index: '4',
          },
          {
            id: 4,
            name: "产品溯源",
            ename: "prouctionOrigin",
            menu: 0,
            route: "/origin",
            icon: "TrendCharts",
            index: '5'
          },
          {
            id: 5,
            name: "生产管理",
            ename: "productManage",
            menu: 1,
            route: "",
            icon: "Histogram",
            index: '6',
            children: [
              {
                id: 50,
                name: '农事记录',
                ename: 'record',
                menu: 0,
                route: '/record',
                icon: 'Calendar',
                index: '7'
              }
            ]
          }
        ]
      }
    }
  }
] as MockMethod[]